<?php 
/**
   Template Name: Home Page
 * Concept: Optional custom home page layout
 * Copyright 2011 www.gradientpixels.ca
 * Theme: Incantation
 */

get_header(); ?>

<?php if ( of_get_option('show_cta') ) : // display the Read More text link or button?>
	<div id="content-wrapper" class="clearfix" style="padding-top:0;" >
		<?php get_template_part( 'inc/cta' ); ?>
	<?php else : ?>
		<div id="content-wrapper" class="clearfix" >
<?php endif; ?>		
<div class="w960">
		<div id="content-main" role="main">
		
<?php the_post(); ?>
				<article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
					<div class="fpwrapper">
					<?php if ( of_get_option('show_fp_title') ) { // Shows or hides this group ?>
						<header class="entry-header">
							<h1 class="entry-title"><?php the_title(); ?></h1>
						</header><!-- .entry-header -->	
					<?php } ?>					
						<div class="row entry-content clearfix">							
							<?php the_content(); ?>
						</div><!-- .entry-content -->
					</div>
						
					<?php if ( of_get_option('fp_blog_area') ) { // Shows or hides this group ?>				
						<div class="fpwrapper">
							<?php get_template_part( 'inc/mini-blog' ); // load the mini blog ?>
						</div>
					<?php } ?>


					<?php if ( of_get_option('fp_sidebar_area') ) { // Shows or hides this group ?>						
						<div class="fpwrapper">
							<?php get_template_part( 'inc/sidebar-bottom' ); // load the front page sidebar group ?>
						</div>
					<?php } ?>
										
					<footer class="entry-meta">
						<?php edit_post_link( __( 'Edit', 'gp' ), '<span class="edit-link">', '</span>' ); ?>
					</footer><!-- .entry-meta -->					
			</article><!-- #post-<?php the_ID(); ?> -->	
		</div><!-- #content-main -->			
	</div><!-- .w960 -->
</div><!-- #content-wrapper -->		

<?php get_footer(); ?>